#import <Foundation/Foundation.h>
typedef void(^CYHttpRequestSuccess)(id responseObject);
typedef void(^CYHttpRequestFailed)(NSString *error);
typedef void(^CYHttpRequestFailedV3)(NSString *error,NSInteger code);
typedef void(^CYHttpRequestCache)(id responseCache);
@interface CYNET : NSObject
+ (__kindof NSURLSessionTask *)POST:(NSString *)URL
                         parameters:(id)parameters
                      responseCache:(CYHttpRequestSuccess)responseCache
                            success:(CYHttpRequestSuccess)success
                            failure:(CYHttpRequestFailed)failure hasCache:(BOOL)cache;
+ (__kindof NSURLSessionTask *)POSTv2:(NSString *)URL
                         parameters:(id)parameters
                      responseCache:(CYHttpRequestSuccess)responseCache
                            success:(CYHttpRequestSuccess)success
                            failure:(CYHttpRequestFailed)failure hasCache:(BOOL)cache;
+ (__kindof NSURLSessionTask *)POSTv3:(NSString *)URL
                           parameters:(id)parameters
                        responseCache:(CYHttpRequestSuccess)responseCache
                              success:(CYHttpRequestSuccess)success
                              failure:(CYHttpRequestFailedV3)failure hasCache:(BOOL)cache;
@end
